﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace MvcMovie.Controllers
{
    public class HelloWorldController : Controller
    {
        public ActionResult Index()
        {
            return View();
        }

        // GET: HelloWorld
        //public string Index()
        //{
        //    return "This is my <b>default</b> action...";
        //}

        //public string welcome(string name, int numTimes = 1)
        //{
        //    return HttpUtility.HtmlEncode("Hello= " + name + ", NumTimes=" + numTimes);
        //}

        //public string welcome(string name, int ID = 1)
        //{
        //    return HttpUtility.HtmlEncode("Hello= " + name + ", ID=" + ID);
        //}

        public ActionResult Welcome(string name,int numTimes = 1)
        {
            ViewBag.Message = "Hello " + name;
            ViewBag.NumTimes = numTimes;

            return View();
        }

        public string Hi()
        {
            return "Hi Man,Yo Man";
        }

        public string h1()
        {
            return "H11111111111";
        }
    }
}